package com.yyfax.pay.third.model.to.fuiou;

import com.yyfax.framework.model.Params;
import com.yyfax.framework.yyfax.enums.RspCodeEnum;
import com.yyfax.pay.common.exception.YYPayException;

/**
 * 通过富友订单号查询订单结果参数
 * 
 * @author heizq
 * @date 2017-04-12 10:23:38
 * @since v1.0.0
 */
@SuppressWarnings({ "serial" })
public class QueryOrderByFuiouOrderNumParams extends Params {

	/**
	 * 富友订单号
	 */
	private String fuiouOrderNum;

	/**
	 * 商户号
	 */
	private String merchantId;

	/**
	 * 获取验证码URL
	 */
	private String url;

	/**
	 * 商户密钥
	 */
	private String merchantSecurit;

	/**
	 * 查单参数
	 */
	private String param;

	@Override
	public boolean validate() throws Exception {
		if (this.fuiouOrderNum == null) {
			throw new YYPayException(RspCodeEnum.COMMON_ERROR_PARAMETER_INVALID, "fuiouOrderNum参数不能为空");
		}
		if (this.merchantId == null) {
			throw new YYPayException(RspCodeEnum.COMMON_ERROR_PARAMETER_INVALID, "merchantId参数不能为空");
		}
		if (this.url == null) {
			throw new YYPayException(RspCodeEnum.COMMON_ERROR_PARAMETER_INVALID, "url参数不能为空");
		}
		if (this.merchantSecurit == null) {
			throw new YYPayException(RspCodeEnum.COMMON_ERROR_PARAMETER_INVALID, "merchantSecurit参数不能为空");
		}
		if (this.param == null) {
			throw new YYPayException(RspCodeEnum.COMMON_ERROR_PARAMETER_INVALID, "param参数不能为空");
		}
		return false;
	}

	public String getFuiouOrderNum() {
		return fuiouOrderNum;
	}

	public void setFuiouOrderNum(String fuiouOrderNum) {
		this.fuiouOrderNum = fuiouOrderNum;
	}

	public String getMerchantId() {
		return merchantId;
	}

	public void setMerchantId(String merchantId) {
		this.merchantId = merchantId;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getMerchantSecurit() {
		return merchantSecurit;
	}

	public void setMerchantSecurit(String merchantSecurit) {
		this.merchantSecurit = merchantSecurit;
	}

	public String getParam() {
		return param;
	}

	public void setParam(String param) {
		this.param = param;
	}
}
